import { createRouter, createWebHashHistory, RouteRecordRaw } from 'vue-router'
import Layout from '../components/HelloWorld.vue'

const routes: Array<RouteRecordRaw> = [
  {
  //路由初始指向
    path: '/',
    name: 'middlepages',
    component:()=>import('@/views/middlepages/index.vue'),
  },
  {
    //路由初始指向
      path: '/about',
      name: 'about',
      component:()=>import('@/views/about/index.vue'),
    },
  {
    //路由初始指向
      path: '/helloword',
      name: 'HelloWorld',
      component:()=>import('@/components/HelloWorld.vue'),
    }
]

const router = createRouter({
  history: createWebHashHistory(),
  routes
})

export default router
